package leetcode.L500;

public class EX283 {
    public static void main(String[] args) {

        int[] nums = {0,1,0,0,3,12};

        for(int i = 0 ;i<nums.length;i++){
            if(nums[i]==0){
                for(int j = i;j<nums.length-1;j++){
                    int temp = nums[j+1];
                    nums[j+1] = nums[j];
                    nums[j] = temp;
                }

            }
            if(nums[i]==0){
                i--;
            }
        }

    }

}
